<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%String path = request.getContextPath();%>
<%@ taglib uri="/WEB-INF/tld/c.tld" prefix="c" %>
<%@ taglib prefix="sys" uri="/WEB-INF/tld/sys.tld" %>
<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <title>优车销售经理</title>
    <jsp:include page="../../import.jsp" flush="true"/>
    <style type="text/css">
        .searchArea .fieldBox .label{width: 70px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis;}
    </style>
</head>

<body class="iframeBody">
<div class="Wrapper">
    <div class="searchArea">
        <form id="searchBar">
            <div class="fieldset1 clearFix">
                <div class="fieldBox col_50">
                    <div class="label" style="width:50px;">工号</div>
                    <div class="field">
                        <input name="userName" id="userName" type="text" class="ui-textbox" value="" ligerui="width: 100"/>
                    </div>
                </div>

                <div class="fieldBox col_50">
                    <div class="formBtns notRight">
                        <span id="searchBtn" class="sq-button sq-button-round"></i>查询</span>
                        <span id="clearBtn" class="sq-button sq-button-round"></i>清空</span>
                        <input id="resetBtn" type="reset" value="重置" class="l-button l-button-reset Hide"/>
                    </div>
                </div>
            </div>
        </form>
    </div>

    <div id="sell_manager_grid" class="sq-grid"></div>
    </div>
</div>

<script type="text/javascript">
    var basePath = '<%=path%>';
    var g = null;
    $(function () {

        g = $("#sell_manager_grid").ligerGrid({
            url: basePath + '/ass/ucardeal/searchSellManagerList.do',
            method: 'get',
            columns: [
                {display: '用户ID', name: 'dealSellMgrId', width: 2, hide: true, align: 'center', enabledSort: false},
                {display: '工号', name: 'dealSellMgrUsrNm', minWidth: 180, align: 'center', enabledSort: false},
                {display: '真实姓名', name: 'dealSellMgrRlNm', minWidth: 180, align: 'center', enabledSort: false}
            ],
            usePager: false,
            root: 'rows',
            record: 'total',
            width: '100%',
            height: 300,
            checkbox: true,
            isSingleCheck: true,
            rownumbers: true
        });

        $("#searchBar").ligerForm();
        $("#pageloading").hide();

        /* 查询 */
        $("#searchBtn").click(function (event) {
            var form = liger.get("searchBar");
            var data = form.getData();
            for (name in data) {
                g.setParm(name, data[name]);
            }
            g.reload();
        });

        /* 清空 */
        $("#clearBtn").click(function (event) {
            $("#resetBtn").click();  //重置 input-text
        });

    });

    function f_select() {
        return g.getSelectedRow();
    }

</script>

</body>
</html>
